package com.ruoyi.ai.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.TreeEntity;

import javax.validation.constraints.NotNull;

/**
 * 评论管理对象 ai_comment
 *
 * @author tang
 * @date 2024-12-09
 */
public class AiComment extends TreeEntity
{
    private static final long serialVersionUID = 1L;

    /** 评论ID */
    private Long commentId;

    /** 用户ID */
    @Excel(name = "用户ID")
    @NotNull(message = "用户不能为空")
    private Long userId;

    /** 作品ID */
    @Excel(name = "作品ID")
    @NotNull(message = "作品不能为空")
    private Long workId;

    /** 父ID（用于表示回复关系） */
    @Excel(name = "父ID", readConverterExp = "用=于表示回复关系")
    @NotNull(message = "回复评论不能为空")
    private Long parentCommentId;

    /** 评论内容 */
    @Excel(name = "评论内容")
    private String content;

    /** 删除标志（0代表存在 2代表删除） */
    private String delFlag;

    public void setCommentId(Long commentId)
    {
        this.commentId = commentId;
    }

    public Long getCommentId()
    {
        return commentId;
    }
    public void setUserId(Long userId)
    {
        this.userId = userId;
    }

    public Long getUserId()
    {
        return userId;
    }
    public void setWorkId(Long workId)
    {
        this.workId = workId;
    }

    public Long getWorkId()
    {
        return workId;
    }
    public void setParentCommentId(Long parentCommentId)
    {
        this.parentCommentId = parentCommentId;
    }

    public Long getParentCommentId()
    {
        return parentCommentId;
    }
    public void setContent(String content)
    {
        this.content = content;
    }

    public String getContent()
    {
        return content;
    }
    public void setDelFlag(String delFlag)
    {
        this.delFlag = delFlag;
    }

    public String getDelFlag()
    {
        return delFlag;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("commentId", getCommentId())
                .append("userId", getUserId())
                .append("workId", getWorkId())
                .append("parentCommentId", getParentCommentId())
                .append("content", getContent())
                .append("delFlag", getDelFlag())
                .append("createBy", getCreateBy())
                .append("createTime", getCreateTime())
                .append("updateBy", getUpdateBy())
                .append("updateTime", getUpdateTime())
                .append("remark", getRemark())
                .toString();
    }
}
